package fun.codedesign.datasource.spring.boot.autoconfigure;


import lombok.Data;
import org.springframework.boot.autoconfigure.jdbc.DataSourceProperties;
import org.springframework.boot.context.properties.ConfigurationProperties;

import java.util.List;

@ConfigurationProperties(prefix = "tenant")
@Data
public class TenantProperties {

    /**
     * 是否开启该功能
     */
    private Boolean enable;

    /**
     * 租户名称
     */
    private String name;

    /**
     * 租户数据源
     */
    private List<TenantDataSourceProperties> datasourceList;


    @Data
    static class TenantDataSourceProperties extends DataSourceProperties {

    }


}
